package utils
{
	import flash.events.Event;
	
	import org.un.cava.birdeye.ravis.enhancedGraphLayout.event.VGNodeEvent;
	import org.un.cava.birdeye.ravis.graphLayout.data.INode;

	public class ClassEvent extends VGNodeEvent
	{
		
		
		public static var NAME_CHANGE:String = "name_changed";
		public static var POSITION_CHANGE:String = "position_changed";
		public static var ATTRIBUTE_CHANGE:String  = "attributes_changed";
		
		private var _name:String;
		
		private var _attr:String;
		private var _attrVal:String;
		private var _attrVisibility:String;
		
		public function ClassEvent(type:String, currentNode:INode=null, flexEvt:Event=null, bubbles:Boolean=false, cancelable:Boolean=false)
		{
			
			super(type, currentNode, flexEvt, bubbles, cancelable);
		}
		
		public function set modifiedName(name:String):void{
			_name = name;
		}
		public function get modifiedName():String{
			return _name;
		}
		public function get id():Number{
			return node.id;
		}
		
		
		public function setModifiedAttribute(attr:String, attrVal:String, attrVisi:String):void{
			_attr = attr;
			_attrVal = attrVal;
			_attrVisibility = attrVisi;
		}
		public function get modifiedAttribute():String{
			return _attr;
		}
		public function get modifiedAttributeValue():String{
			return _attrVal;
		}
		public function get modifiedAttributeVisibility():String{
			return _attrVisibility;
		}
		public function get modifiedX():Number{
			return node.vnode.viewX;
		}
		public function get modifiedY():Number{
			return node.vnode.viewY;
		}
	}
}